<?php
class PC4_Controlador_Plugin_InitJS extends Zend_Controller_Plugin_Abstract {
	
	public function preDispatch($request) {
        $layout = Zend_Layout::getMvcInstance();
        $view = $layout->getView();
        $baseUrl = $view->baseUrl('');
		$view->headScript()->prependScript('var BASE_URL = "' . $baseUrl . '";');
	}
	
}